package com.wicket.okrpbff.web.contorller;

import cn.hutool.core.bean.BeanUtil;
import com.wicket.okrpbff.biz.service.MessageService;
import com.wicket.okrpbff.biz.service.dto.req.*;
import com.wicket.okrpbff.biz.service.dto.res.*;
import com.wicket.okrpbff.common.ro.OkrResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import java.util.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.wicket.okrcomponent.integration.FwCompMessageClient;
import com.wicket.okrcomponent.integration.dto.ArchiveMessagePositionRespDto;
import com.wicket.okrcomponent.integration.dto.ArchiveMessagePositionReqDto;
import com.wicket.okrpbff.common.exception.Assert;
import com.wicket.okrcomponent.integration.dto.AddMessageTemplateRespDto;
import com.wicket.okrcomponent.integration.dto.AddMessageTemplateReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMessageTemplateListRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMessageTemplateListReqDto;
import com.wicket.okrframework.integration.FwBaseInductionRecordClient;
import com.wicket.okrframework.integration.dto.BatchQueryInductionRecordComRespDto;
import com.wicket.okrframework.integration.dto.BatchQueryInductionRecordComReqDto;
import java.util.stream.Collectors;
import cn.hutool.core.collection.CollectionUtil;
import com.wicket.okrcomponent.integration.dto.AddVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.AddVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.UpdateVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.UpdateVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.DeleteVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.DeleteVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.ArchiveVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.ArchiveVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.QueryVirtualImageDetailRespDto;
import com.wicket.okrcomponent.integration.dto.QueryVirtualImageDetailReqDto;
import com.wicket.okrframework.integration.dto.QueryInductionRecordInfoDetailComRespDto;
import com.wicket.okrframework.integration.dto.QueryInductionRecordInfoDetailComReqDto;
import com.wicket.okrcomponent.integration.dto.QueryVirtualImageListRespDto;
import com.wicket.okrcomponent.integration.dto.QueryVirtualImageListReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMemberVirtualImageDetailRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMemberVirtualImageDetailReqDto;
import com.wicket.okrcomponent.integration.dto.ArchiveMemberVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.ArchiveMemberVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.AddMemberVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.AddMemberVirtualImageReqDto;
import com.wicket.okrpbff.common.util.CommonFunctionHelper;
import com.wicket.okrcomponent.integration.dto.DeleteMemberVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.DeleteMemberVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMemberVirtualImageListRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMemberVirtualImageListReqDto;
import com.wicket.okrcomponent.integration.dto.UpdateMessageTemplateRespDto;
import com.wicket.okrcomponent.integration.dto.UpdateMessageTemplateReqDto;
import com.wicket.okrcomponent.integration.dto.DeleteMessageTemplateRespDto;
import com.wicket.okrcomponent.integration.dto.DeleteMessageTemplateReqDto;
import com.wicket.okrcomponent.integration.dto.ArchiveMessageTemplateRespDto;
import com.wicket.okrcomponent.integration.dto.ArchiveMessageTemplateReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMessageTemplateDetailRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMessageTemplateDetailReqDto;
import com.wicket.okrcomponent.integration.dto.AddMessagePositionRespDto;
import com.wicket.okrcomponent.integration.dto.AddMessagePositionReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMessagePositionDetailRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMessagePositionDetailReqDto;
import com.wicket.okrframework.integration.dto.QueryInductionRecordDetailBorderRespDto;
import com.wicket.okrframework.integration.dto.QueryInductionRecordDetailBorderReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMessagePositionListRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMessagePositionListReqDto;
import com.wicket.okrframework.integration.dto.BatchQueryInductionRecordListComRespDto;
import com.wicket.okrframework.integration.dto.BatchQueryInductionRecordListComReqDto;
import com.wicket.okrcomponent.integration.dto.DeleteMessagePositionRespDto;
import com.wicket.okrcomponent.integration.dto.DeleteMessagePositionReqDto;
import com.wicket.okrcomponent.integration.dto.UpdateMessagePositionRespDto;
import com.wicket.okrcomponent.integration.dto.UpdateMessagePositionReqDto;
import com.wicket.okrcomponent.integration.dto.UpdateMemberVirtualImageRespDto;
import com.wicket.okrcomponent.integration.dto.UpdateMemberVirtualImageReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMemberVirtualImageDetailComRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMemberVirtualImageDetailComReqDto;
import com.wicket.okrcomponent.integration.dto.QueryMessagePositionDetailComRespDto;
import com.wicket.okrcomponent.integration.dto.QueryMessagePositionDetailComReqDto;
import com.wicket.okrapp.integration.FwAppMessageClient;
import com.wicket.okrapp.integration.dto.ImplementMultiSpaceCompinitMsgLocQtyComRespDto;
import com.wicket.okrapp.integration.dto.ImplementMultiSpaceCompinitMsgLocQtyComReqDto;

/**
 * @author ：
 * @date ：
 *
 *
 * @version 1.0
 */
@Api(value = "Message", tags = { "Message" })
@RestController
// @RequestMapping("/poms/message/")
public class MessageController {

  @Autowired
  MessageService messageService;
/**
   * B2存档消息位置(管理)
   * gen by moon at 5/16/2023, 9:19:41 PM
   */
    @PostMapping("/oms/platform/mgt/message/archiveMessagePosition")
    @ApiOperation(value = "B2存档消息位置(管理)", response = OkrResult.class)
    public OkrResult<BffArchiveMessagePositionRespDto> archiveMessagePosition(@RequestBody(required=false) @Validated BffArchiveMessagePositionReqDto reqDTO){
        return OkrResult.success(messageService.archiveMessagePosition(reqDTO));
    }
/**
   * B2新增消息模板(管理)
   * gen by moon at 5/16/2023, 9:28:54 PM
   */
    @PostMapping("/oms/platform/mgt/message/addMessageTemplate")
    @ApiOperation(value = "B2新增消息模板(管理)", response = OkrResult.class)
    public OkrResult<BffAddMessageTemplateRespDto> addMessageTemplate(@RequestBody(required=false) @Validated BffAddMessageTemplateReqDto reqDTO){
        return OkrResult.success(messageService.addMessageTemplate(reqDTO));
    }
/**
   * B2查询消息模板列表(管理)
   * gen by moon at 5/16/2023, 9:28:57 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryMessageTemplateList")
    @ApiOperation(value = "B2查询消息模板列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryMessageTemplateListRespDto> queryMessageTemplateList(@RequestBody(required=false) @Validated BffQueryMessageTemplateListReqDto reqDTO){
        return OkrResult.success(messageService.queryMessageTemplateList(reqDTO));
    }
/**
   * B2新增虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:28:59 PM
   */
    @PostMapping("/oms/platform/mgt/message/addVirtualImage")
    @ApiOperation(value = "B2新增虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffAddVirtualImageRespDto> addVirtualImage(@RequestBody(required=false) @Validated BffAddVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.addVirtualImage(reqDTO));
    }
/**
   * B2修改虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:29:02 PM
   */
    @PostMapping("/oms/platform/mgt/message/updateVirtualImage")
    @ApiOperation(value = "B2修改虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffUpdateVirtualImageRespDto> updateVirtualImage(@RequestBody(required=false) @Validated BffUpdateVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.updateVirtualImage(reqDTO));
    }
/**
   * B2删除虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:29:04 PM
   */
    @PostMapping("/oms/platform/mgt/message/deleteVirtualImage")
    @ApiOperation(value = "B2删除虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffDeleteVirtualImageRespDto> deleteVirtualImage(@RequestBody(required=false) @Validated BffDeleteVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.deleteVirtualImage(reqDTO));
    }
/**
   * B2存档虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:29:07 PM
   */
    @PostMapping("/oms/platform/mgt/message/archiveVirtualImage")
    @ApiOperation(value = "B2存档虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffArchiveVirtualImageRespDto> archiveVirtualImage(@RequestBody(required=false) @Validated BffArchiveVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.archiveVirtualImage(reqDTO));
    }
/**
   * B2查询虚拟形象详情(管理)
   * gen by moon at 5/16/2023, 9:29:09 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryVirtualImageDetail")
    @ApiOperation(value = "B2查询虚拟形象详情(管理)", response = OkrResult.class)
    public OkrResult<BffQueryVirtualImageDetailRespDto> queryVirtualImageDetail(@RequestBody(required=false) @Validated BffQueryVirtualImageDetailReqDto reqDTO){
        return OkrResult.success(messageService.queryVirtualImageDetail(reqDTO));
    }
/**
   * B2查询虚拟形象列表(管理)
   * gen by moon at 5/16/2023, 9:29:12 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryVirtualImageList")
    @ApiOperation(value = "B2查询虚拟形象列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryVirtualImageListRespDto> queryVirtualImageList(@RequestBody(required=false) @Validated BffQueryVirtualImageListReqDto reqDTO){
        return OkrResult.success(messageService.queryVirtualImageList(reqDTO));
    }
/**
   * B2新增成员虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:29:15 PM
   */
    @PostMapping("/oms/platform/mgt/message/addMemberVirtualImage")
    @ApiOperation(value = "B2新增成员虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffAddMemberVirtualImageRespDto> addMemberVirtualImage(@RequestBody(required=false) @Validated BffAddMemberVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.addMemberVirtualImage(reqDTO));
    }
/**
   * B2存档成员虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:29:17 PM
   */
    @PostMapping("/oms/platform/mgt/message/archiveMemberVirtualImage")
    @ApiOperation(value = "B2存档成员虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffArchiveMemberVirtualImageRespDto> archiveMemberVirtualImage(@RequestBody(required=false) @Validated BffArchiveMemberVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.archiveMemberVirtualImage(reqDTO));
    }
/**
   * B2删除成员虚拟形象(管理)
   * gen by moon at 5/16/2023, 9:29:19 PM
   */
    @PostMapping("/oms/platform/mgt/message/deleteMemberVirtualImage")
    @ApiOperation(value = "B2删除成员虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffDeleteMemberVirtualImageRespDto> deleteMemberVirtualImage(@RequestBody(required=false) @Validated BffDeleteMemberVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.deleteMemberVirtualImage(reqDTO));
    }
/**
   * B2查询成员虚拟形象详情(管理)
   * gen by moon at 5/16/2023, 9:29:21 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryMemberVirtualImageDetail")
    @ApiOperation(value = "B2查询成员虚拟形象详情(管理)", response = OkrResult.class)
    public OkrResult<BffQueryMemberVirtualImageDetailRespDto> queryMemberVirtualImageDetail(@RequestBody(required=false) @Validated BffQueryMemberVirtualImageDetailReqDto reqDTO){
        return OkrResult.success(messageService.queryMemberVirtualImageDetail(reqDTO));
    }
/**
   * B2查询成员虚拟形象列表(管理)
   * gen by moon at 5/16/2023, 9:29:24 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryMemberVirtualImageList")
    @ApiOperation(value = "B2查询成员虚拟形象列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryMemberVirtualImageListRespDto> queryMemberVirtualImageList(@RequestBody(required=false) @Validated BffQueryMemberVirtualImageListReqDto reqDTO){
        return OkrResult.success(messageService.queryMemberVirtualImageList(reqDTO));
    }
/**
   * B2修改消息模板(管理)
   * gen by moon at 5/16/2023, 9:29:27 PM
   */
    @PostMapping("/oms/platform/mgt/message/updateMessageTemplate")
    @ApiOperation(value = "B2修改消息模板(管理)", response = OkrResult.class)
    public OkrResult<BffUpdateMessageTemplateRespDto> updateMessageTemplate(@RequestBody(required=false) @Validated BffUpdateMessageTemplateReqDto reqDTO){
        return OkrResult.success(messageService.updateMessageTemplate(reqDTO));
    }
/**
   * B2删除消息模板(管理)
   * gen by moon at 5/16/2023, 9:29:30 PM
   */
    @PostMapping("/oms/platform/mgt/message/deleteMessageTemplate")
    @ApiOperation(value = "B2删除消息模板(管理)", response = OkrResult.class)
    public OkrResult<BffDeleteMessageTemplateRespDto> deleteMessageTemplate(@RequestBody(required=false) @Validated BffDeleteMessageTemplateReqDto reqDTO){
        return OkrResult.success(messageService.deleteMessageTemplate(reqDTO));
    }
/**
   * B2存档消息模板(管理)
   * gen by moon at 5/16/2023, 9:29:33 PM
   */
    @PostMapping("/oms/platform/mgt/message/archiveMessageTemplate")
    @ApiOperation(value = "B2存档消息模板(管理)", response = OkrResult.class)
    public OkrResult<BffArchiveMessageTemplateRespDto> archiveMessageTemplate(@RequestBody(required=false) @Validated BffArchiveMessageTemplateReqDto reqDTO){
        return OkrResult.success(messageService.archiveMessageTemplate(reqDTO));
    }
/**
   * B2查询消息模板详情(管理)
   * gen by moon at 5/16/2023, 9:29:36 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryMessageTemplateDetail")
    @ApiOperation(value = "B2查询消息模板详情(管理)", response = OkrResult.class)
    public OkrResult<BffQueryMessageTemplateDetailRespDto> queryMessageTemplateDetail(@RequestBody(required=false) @Validated BffQueryMessageTemplateDetailReqDto reqDTO){
        return OkrResult.success(messageService.queryMessageTemplateDetail(reqDTO));
    }
/**
   * B2-5新增消息位置(管理)
   * gen by moon at 5/16/2023, 9:29:40 PM
   */
    @PostMapping("/oms/platform/mgt/message/addMessagePosition")
    @ApiOperation(value = "B2-5新增消息位置(管理)", response = OkrResult.class)
    public OkrResult<BffAddMessagePositionRespDto> addMessagePosition(@RequestBody(required=false) @Validated BffAddMessagePositionReqDto reqDTO){
        return OkrResult.success(messageService.addMessagePosition(reqDTO));
    }
/**
   * B2-5查询消息位置详情(管理)
   * gen by moon at 5/16/2023, 9:29:43 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryMessagePositionDetail")
    @ApiOperation(value = "B2-5查询消息位置详情(管理)", response = OkrResult.class)
    public OkrResult<BffQueryMessagePositionDetailRespDto> queryMessagePositionDetail(@RequestBody(required=false) @Validated BffQueryMessagePositionDetailReqDto reqDTO){
        return OkrResult.success(messageService.queryMessagePositionDetail(reqDTO));
    }
/**
   * B2-5查询消息位置列表(管理)
   * gen by moon at 5/16/2023, 9:29:46 PM
   */
    @PostMapping("/oms/platform/mgt/message/queryMessagePositionList")
    @ApiOperation(value = "B2-5查询消息位置列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryMessagePositionListRespDto> queryMessagePositionList(@RequestBody(required=false) @Validated BffQueryMessagePositionListReqDto reqDTO){
        return OkrResult.success(messageService.queryMessagePositionList(reqDTO));
    }
/**
   * B2-5删除消息位置(管理)
   * gen by moon at 5/16/2023, 9:29:50 PM
   */
    @PostMapping("/oms/platform/mgt/message/deleteMessagePosition")
    @ApiOperation(value = "B2-5删除消息位置(管理)", response = OkrResult.class)
    public OkrResult<BffDeleteMessagePositionRespDto> deleteMessagePosition(@RequestBody(required=false) @Validated BffDeleteMessagePositionReqDto reqDTO){
        return OkrResult.success(messageService.deleteMessagePosition(reqDTO));
    }
/**
   * B2-5修改消息位置(管理)
   * gen by moon at 5/16/2023, 9:29:53 PM
   */
    @PostMapping("/oms/platform/mgt/message/updateMessagePosition")
    @ApiOperation(value = "B2-5修改消息位置(管理)", response = OkrResult.class)
    public OkrResult<BffUpdateMessagePositionRespDto> updateMessagePosition(@RequestBody(required=false) @Validated BffUpdateMessagePositionReqDto reqDTO){
        return OkrResult.success(messageService.updateMessagePosition(reqDTO));
    }
/**
   * B2关闭或启用成员虚拟形象(管理)
   * gen by moon at 6/2/2023, 8:24:12 PM
   */
    @PostMapping("/oms/platform/mgt/message/updateMemberVirtualImage")
    @ApiOperation(value = "B2关闭或启用成员虚拟形象(管理)", response = OkrResult.class)
    public OkrResult<BffUpdateMemberVirtualImageRespDto> updateMemberVirtualImage(@RequestBody(required=false) @Validated BffUpdateMemberVirtualImageReqDto reqDTO){
        return OkrResult.success(messageService.updateMemberVirtualImage(reqDTO));
    }
/**
   * B3-执行多空间补偿初始化消息数量（平台）
   * gen by moon at 1/25/2024, 3:06:05 AM
   */
    @PostMapping("/oms/platform/message/implementMultiSpaceCompinitMsgLocQty")
    @ApiOperation(value = "B3-执行多空间补偿初始化消息数量（平台）", response = OkrResult.class)
    public OkrResult<BffImplementMultiSpaceCompinitMsgLocQtyRespDto> implementMultiSpaceCompinitMsgLocQty(@RequestBody(required=false) @Validated BffImplementMultiSpaceCompinitMsgLocQtyReqDto reqDTO){
        return OkrResult.success(messageService.implementMultiSpaceCompinitMsgLocQty(reqDTO));
    }
}
